package com.franklin.ideaplugin.maphelper.col.operation.impl.map;

import com.franklin.ideaplugin.maphelper.col.method.IColQueryMethod;
import com.franklin.ideaplugin.maphelper.col.method.impl.DefaultColQueryMethod;

import java.util.Set;
import java.util.SortedMap;

/**
 * sortedMap
 *
 * @author Ye Junhui
 * @since 2024/3/12
 */
public class SortedMapReadWriteOperation extends MapReadWriteOperation {
    @Override
    public String getClassQualifiedName() {
        return SortedMap.class.getName();
    }

    @Override
    public Set<IColQueryMethod> getQueryMethods() {
        Set<IColQueryMethod> queryMethods = super.getQueryMethods();
        queryMethods.add(new DefaultColQueryMethod("subMap", 2, -1));
        queryMethods.add(new DefaultColQueryMethod("headMap", 1, -1));
        queryMethods.add(new DefaultColQueryMethod("tailMap", 1, -1));
        return queryMethods;
    }
}
